package org.metasketch.ham.model;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;

@XStreamAlias("human-activity-link")
public class HumanActivityRelationLink extends HumanActivityElement {

	// by id
	@XStreamAsAttribute
	@XStreamAlias("source-activity")
	HumanActivityElement source;

	// by id
	@XStreamAsAttribute
	@XStreamAlias("target-activity")
	HumanActivityElement target;

	@XStreamAsAttribute
	HumanActivityRelationType type = HumanActivityRelationType.PRECEDES;

	@XStreamAsAttribute
	boolean optional = false;

	public HumanActivityElement getSource() {
		return source;
	}

	public void setSource(HumanActivityElement source) {
		this.source = source;
	}

	public HumanActivityElement getTarget() {
		return target;
	}

	public void setTarget(HumanActivityElement target) {
		this.target = target;
	}

	public HumanActivityRelationType getType() {
		return type;
	}

	public void setType(HumanActivityRelationType type) {
		this.type = type;
	}

	public boolean isOptional() {
		return optional;
	}

	public void setOptional(boolean optional) {
		this.optional = optional;
	}

}
